<!DOCTYPE html>
<html  lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <!--360浏览器优先以webkit内核解析-->
    <title>人体运动功能检测评估报告</title>
    <link rel="shortcut icon" href="favicon.ico">
    <link href="../static/css/bootstrap.min.css" th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
    <link href="../static/css/font-awesome.min.css" th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/>
    <link href="../static/css/style.min.css" th:href="@{/css/style.min.css}" rel="stylesheet"/>
    <th:block th:include="include :: header('日期和时间')" />
    <th:block th:include="include :: datetimepicker-css" />
</head>

<body class="gray-bg">
<script th:src="@{/js/jquery.min.js}"></script>
<script th:src="@{/js/bootstrap.min.js}"></script>
<script th:src="@{/ajax/libs/layer/layer.min.js}"></script>
<script th:src="@{/js/sockjs.min.js}"></script>
<script th:src="@{/js/stomp.js}"></script>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script type="text/javascript">
    var stomp = null;
    var url = "https://sunfu.xdkdate.com/webSocket"
    // var url = "http://localhost:8009/webSocket"
    // var url = "https://www.bythealthy.com/sunfu/webSocket"
    var socket = new SockJS(url);
    stomp = Stomp.over(socket);
    //连接
    stomp.connect({}, function (frame) {
        //订阅广播
        stomp.subscribe("/user/toilet/message", function (res) {
            // $("#broadcastMsg").val(res.body);
            console.log(res.body)
        });
    });
</script>
</body>
</html>
